package org.nimi317.web_gis.Enum;

import com.alibaba.fastjson2.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.EnumValue;
import com.fasterxml.jackson.annotation.JsonValue;
import lombok.AllArgsConstructor;

import java.util.Map;

/**
 * @author thunderobot
 */
@AllArgsConstructor
public enum InterpolateEnum {

    Kriging(0, "克里金"),
    Idw(1, "反距离权重");

    @EnumValue
    @JsonValue
    @JSONField
    private final int code;

    private final String value;

    public Map<String, ?> getObject() {
        return Map.of("code", code, "value", value);
    }
}
